package com.mxdx.edu.service.impl;

import java.util.List;
import java.util.Map;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.mxdx.edu.dao.UserJobSeekerDao;
import com.mxdx.edu.model.UserJobSeekerInfo;
import com.mxdx.edu.service.IUserJobSeekerService;

@Service
public class UserJobSeekerService implements IUserJobSeekerService {
	
	@Resource
	private UserJobSeekerDao userJobSeekerDao;

	@Override
	public void save(UserJobSeekerInfo userJobSeekerInfo) {
		userJobSeekerDao.save(userJobSeekerInfo);
	}

	@Override
	public Map<String, Object> findJobSeekerMapByMap(Map<String, Object> param) {
		List<Map<String, Object>> list = userJobSeekerDao.findListByMap(param);
		if(list != null && list.size() > 0){
			Map<String, Object> map = list.get(0);
			return map;
		}
		return null;
	}

	@Override
	public void update(UserJobSeekerInfo userJobSeekerInfo) {
		userJobSeekerDao.update(userJobSeekerInfo);
	}

	@Override
	public void updateByMap(Map<String, Object> param) {
		userJobSeekerDao.updateByMap(param);
		
	}

	@Override
	public List<Map<String, Object>> findListByMap(Map<String, Object> param) {
		return userJobSeekerDao.findListByMap(param);
	}

}
